home *** CD-ROM | disk | FTP | other *** search
/ SGI Freeware 1999 August / SGI Freeware 1999 August.iso / dist / fw_perl.idb / usr / freeware / catman / u_man / cat1 / perlmodinstall.Z / perlmodinstall
Encoding:
Text File  |  1998-10-28  |  18.3 KB  |  595 lines

  1.  
  2.  
  3.  
  4.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  5.  
  6.  
  7.  
  8.      NNNNAAAAMMMMEEEE
  9.       perlmodinstall - Installing CPAN Modules
  10.  
  11.      DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  12.       You can think    of a module as the fundamental unit of
  13.       reusable Perl    code; see the _p_e_r_l_m_o_d manpage for details.
  14.       Whenever anyone creates a chunk of Perl code that they think
  15.       will be useful to the    world, they register as    a Perl
  16.       developer at http://www.perl.com/CPAN/modules/04pause.html
  17.       so that they can then    upload their code to the CPAN.    The
  18.       CPAN is the Comprehensive Perl Archive Network and can be
  19.       accessed at http://www.perl.com/CPAN/.
  20.  
  21.       This documentation is    for people who want to download    CPAN
  22.       modules and install them on their own    computer.
  23.  
  24.       PPPPRRRREEEEAAAAMMMMBBBBLLLLEEEE
  25.  
  26.       You have a file ending in .tar.gz (or, less often, .zip).
  27.       You know there's a tasty module inside.  There are four
  28.       steps    you must now take:
  29.  
  30.       DDDDEEEECCCCOOOOMMMMPPPPRRRREEEESSSSSSSS the file
  31.  
  32.       UUUUNNNNPPPPAAAACCCCKKKK the file into a directory
  33.  
  34.       BBBBUUUUIIIILLLLDDDD    the module (sometimes unnecessary)
  35.  
  36.       IIIINNNNSSSSTTTTAAAALLLLLLLL the module.
  37.  
  38.       Here's how to    perform    each step for each operating system.
  39.       This is _n_o_t a    substitute for reading the README and INSTALL
  40.       files    that might have    come with your module!
  41.  
  42.       Also note that these instructions are    tailored for
  43.       installing the module    into your system's repository of Perl
  44.       modules.  But    you can    install    modules    into any directory you
  45.       wish.     For instance, where I say perl    Makefile.PL, you can
  46.       substitute perl Makefile.PL PREFIX=/my/perl_directory    to
  47.       install the modules into /my/perl_directory.    Then you can
  48.       use the modules from your Perl programs with use lib
  49.       "/my/perl_directory/lib/site_perl"; or sometimes just    use
  50.       "/my/perl_directory";.
  51.  
  52.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    oooonnnn UUUUnnnniiiixxxx,,,,
  53.  
  54.           You can use Andreas Koenig's CPAN    module (
  55.           http://www.perl.com/CPAN/modules/by-module/CPAN )    to
  56.           automate the following steps, from DECOMPRESS through
  57.           INSTALL.
  58.  
  59.           A. DECOMPRESS
  60.  
  61.  
  62.  
  63.      Page 1                        (printed 10/23/98)
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  71.  
  72.  
  73.  
  74.           Decompress the file with gzip -d yourmodule.tar.gz
  75.  
  76.           You can get gzip from ftp://prep.ai.mit.edu/pub/gnu.
  77.  
  78.           Or, you can combine this step with the next to save disk
  79.           space:
  80.  
  81.            gzip    -dc yourmodule.tar.gz |    tar -xof -
  82.  
  83.           B. UNPACK
  84.  
  85.           Unpack the result    with tar -xof yourmodule.tar
  86.  
  87.           C. BUILD
  88.  
  89.           Go into the newly-created    directory and type:
  90.  
  91.             perl Makefile.PL
  92.             make
  93.             make test
  94.  
  95.           D. INSTALL
  96.  
  97.           While still in that directory, type:
  98.  
  99.             make install
  100.  
  101.           Make sure    you have the appropriate permissions to
  102.           install the module in your Perl 5    library    directory.
  103.           Often, you'll need to be root.
  104.  
  105.           That's all you need to do    on Unix    systems    with dynamic
  106.           linking.    Most Unix systems have dynamic linking -- if
  107.           yours doesn't, or    if for another reason you have a
  108.           statically-linked    perl, aaaannnndddd the module requires
  109.           compilation, you'll need to build    a new Perl binary that
  110.           includes the module.  Again, you'll probably need    to be
  111.           root.
  112.  
  113.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    rrrruuuunnnnnnnniiiinnnngggg    WWWWiiiinnnnddddoooowwwwssss    99995555 oooorrrr NNNNTTTT wwwwiiiitttthhhh tttthhhheeee AAAAccccttttiiiivvvveeeeSSSSttttaaaatttteeee
  114.           ppppoooorrrrtttt ooooffff PPPPeeeerrrrllll
  115.  
  116.          A. DECOMPRESS
  117.  
  118.           You can use the shareware    Winzip ( http://www.winzip.com
  119.           )    to decompress and unpack modules.
  120.  
  121.          B. UNPACK
  122.  
  123.           If you used WinZip, this was already done    for you.
  124.  
  125.          C. BUILD
  126.  
  127.  
  128.  
  129.      Page 2                        (printed 10/23/98)
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  137.  
  138.  
  139.  
  140.           Does the module require compilation (i.e.    does it    have
  141.           files that end in    .xs, .c, .h, .y, .cc, .cxx, or .C)?
  142.           If it does, you're on your own.  You can try compiling
  143.           it yourself if you have a    C compiler.  If    you're
  144.           successful, consider uploading the resulting binary to
  145.           the CPAN for others to use.  If it doesn't, go to
  146.           INSTALL.
  147.  
  148.          D. INSTALL
  149.  
  150.           Copy the module into your    Perl's _l_i_b directory.  That'll
  151.           be one of    the directories    you see    when you type
  152.  
  153.          perl -e 'print    "@INC"'
  154.  
  155.  
  156.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    rrrruuuunnnnnnnniiiinnnngggg    WWWWiiiinnnnddddoooowwwwssss    99995555 oooorrrr NNNNTTTT wwwwiiiitttthhhh tttthhhheeee ccccoooorrrreeee WWWWiiiinnnnddddoooowwwwssss
  157.           ddddiiiissssttttrrrriiiibbbbuuuuttttiiiioooonnnn ooooffff PPPPeeeerrrrllll,,,,
  158.  
  159.          A. DECOMPRESS
  160.  
  161.           When you download    the module, make sure it ends in
  162.           either .tar.gz or    .zip.  Windows browsers    sometimes
  163.           download .tar.gz files as    _tar.tar, because early
  164.           versions of Windows prohibited more than one dot in a
  165.           filename.
  166.  
  167.           You can use the shareware    WinZip ( http://www.winzip.com
  168.           )    to decompress and unpack modules.
  169.  
  170.           Or, you can use InfoZip's    unzip utility (
  171.           http://www.cdrom.com/pub/infozip/Info-Zip.html ) to
  172.           uncompress .zip files; type unzip    yourmodule.zip in your
  173.           shell.
  174.  
  175.           Or, if you have a    working    tar and    gzip, you can type
  176.  
  177.          gzip -cd yourmodule.tar.gz | tar xvf -
  178.  
  179.           in the shell to decompress yourmodule.tar.gz.  This will
  180.           UNPACK your module as well.
  181.  
  182.          B. UNPACK
  183.  
  184.           All of the methods in DECOMPRESS will have done this for
  185.           you.
  186.  
  187.          C. BUILD
  188.  
  189.           Go into the newly-created    directory and type:
  190.  
  191.  
  192.  
  193.  
  194.  
  195.      Page 3                        (printed 10/23/98)
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  203.  
  204.  
  205.  
  206.             perl Makefile.PL
  207.             dmake
  208.             dmake test
  209.  
  210.           Depending    on your    perl configuration, dmake might    not be
  211.           available.  You might have to substitute whatever    perl
  212.           -V:make says. (Usually, that will    be nmake or make.)
  213.  
  214.          D. INSTALL
  215.  
  216.           While still in that directory, type:
  217.  
  218.             dmake install
  219.  
  220.  
  221.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    uuuussssiiiinnnngggg aaaa    MMMMaaaacccciiiinnnnttttoooosssshhhh,,,,
  222.  
  223.           A. DECOMPRESS
  224.  
  225.           You can either use StuffIt Expander (
  226.           http://www.aladdinsys.com/ ) in combination with
  227.           _D_r_o_p_S_t_u_f_f    _w_i_t_h _E_x_p_a_n_d_e_r _E_n_h_a_n_c_e_r (shareware), or the
  228.           freeware MacGzip (
  229.           http://persephone.cps.unizar.es/general/gente/spd/gzip/gzip.html
  230.           ).
  231.  
  232.           B. UNPACK
  233.  
  234.           If you're    using DropStuff    or Stuffit, you    can just
  235.           extract the tar archive.    Otherwise, you can use the
  236.           freeware _s_u_n_t_a_r (    http://www.cirfid.unibo.it/~speranza
  237.           ).
  238.  
  239.           C. BUILD
  240.  
  241.           Does the module require compilation?
  242.  
  243.           1. If it does,
  244.  
  245.           Overview:    You need MPW and a combination of new and old
  246.           CodeWarrior compilers for    MPW and    libraries.  Makefiles
  247.           created for building under MPW use the Metrowerks
  248.           compilers.  It's most likely possible to build without
  249.           other compilers, but it has not been done    successfully,
  250.           to our knowledge.     Read the documentation    in MacPerl:
  251.           Power and    Ease ( http://www.ptf.com/macperl/ ) on
  252.           porting/building extensions, or find an existing
  253.           precompiled binary, or hire someone to build it for you.
  254.  
  255.           Or, ask someone on the mac-perl mailing list (mac-
  256.           perl@iis.ee.ethz.ch) to build it for you.     To subscribe
  257.           to the mac-perl mailing list, send mail to mac-perl-
  258.  
  259.  
  260.  
  261.      Page 4                        (printed 10/23/98)
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  269.  
  270.  
  271.  
  272.           request@iis.ee.ethz.ch.
  273.  
  274.           2. If the    module doesn't require compilation, go to
  275.           INSTALL.
  276.  
  277.           D. INSTALL
  278.  
  279.           Make sure    the newlines for the modules are in Mac
  280.           format, not Unix format.    Move the files manually    into
  281.           the correct folders.
  282.  
  283.           Move the files to    their final destination: This will
  284.           most likely be in    $ENV{MACPERL}site_lib: (i.e.,
  285.           HD:MacPerl folder:site_lib:).  You can add new paths to
  286.           the default @INC in the Preferences menu item in the
  287.           MacPerl application ($ENV{MACPERL}site_lib: is added
  288.           automagically).  Create whatever directory structures
  289.           are required (i.e., for Some::Module, create
  290.           $ENV{MACPERL}site_lib:Some: and put Module.pm in that
  291.           directory).
  292.  
  293.           Run the following    script (or something like it):
  294.  
  295.            #!perl -w
  296.            use AutoSplit;
  297.            my $dir = "${MACPERL}site_perl";
  298.            autosplit("$dir:Some:Module.pm", "$dir:auto", 0, 1, 1);
  299.  
  300.           Eventually there should be a way to automate the
  301.           installation process; some solutions exist, but none are
  302.           ready for    the general public yet.
  303.  
  304.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    oooonnnn tttthhhheeee DDDDJJJJGGGGPPPPPPPP ppppoooorrrrtttt ooooffff DDDDOOOOSSSS,,,,
  305.  
  306.          A. DECOMPRESS
  307.  
  308.           djtarx (
  309.           ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2/ ) will
  310.           both uncompress and unpack.
  311.  
  312.          B. UNPACK
  313.  
  314.           See above.
  315.  
  316.          C. BUILD
  317.  
  318.           Go into the newly-created    directory and type:
  319.  
  320.             perl Makefile.PL
  321.             make
  322.             make test
  323.  
  324.  
  325.  
  326.  
  327.      Page 5                        (printed 10/23/98)
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  335.  
  336.  
  337.  
  338.           You will need the    packages mentioned in Readme.dos in
  339.           the Perl distribution.
  340.  
  341.          D. INSTALL
  342.  
  343.           While still in that directory, type:
  344.  
  345.            make    install
  346.  
  347.           You will need the    packages mentioned in Readme.dos in the    Perl distribution.
  348.  
  349.  
  350.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    oooonnnn OOOOSSSS////2222,,,,
  351.  
  352.           Get the EMX development suite and    gzip/tar, from either
  353.           Hobbes ( http://hobbes.nmsu.edu )    or Leo (
  354.           http://www.leo.org ), and    then follow the    instructions
  355.           for Unix.
  356.  
  357.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    oooonnnn VVVVMMMMSSSS,,,,
  358.  
  359.           When downloading from CPAN, save your file with a    .tgz
  360.           extension    instead    of .tar.gz.  All other periods in the
  361.           filename should be replaced with underscores.  For
  362.           example, Your-Module-1.33.tar.gz should be downloaded as
  363.           Your-Module-1_33.tgz.
  364.  
  365.           A. DECOMPRESS
  366.  
  367.           Type
  368.  
  369.           gzip -d Your-Module.tgz
  370.  
  371.           or, for zipped modules, type
  372.  
  373.           unzip    Your-Module.zip
  374.  
  375.           Executables for gzip, zip, and VMStar ( Alphas:
  376.           http://www.openvms.digital.com/cd/000TOOLS/ALPHA/    and
  377.           Vaxen:  http://www.openvms.digital.com/cd/000TOOLS/VAX/
  378.           ).
  379.  
  380.           gzip and tar are also available at
  381.           ftp://ftp.digital.com/pub/VMS.
  382.  
  383.           Note that    GNU's gzip/gunzip is not the same as Info-
  384.           ZIP's zip/unzip package.    The former is a    simple
  385.           compression tool;    the latter permits creation of multi-
  386.           file archives.
  387.  
  388.           B. UNPACK
  389.  
  390.  
  391.  
  392.  
  393.      Page 6                        (printed 10/23/98)
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  401.  
  402.  
  403.  
  404.           If you're    using VMStar:
  405.  
  406.            VMStar xf Your-Module.tar
  407.  
  408.           Or, if you're fond of VMS    command    syntax:
  409.  
  410.            tar/extract/verbose Your_Module.tar
  411.  
  412.           C. BUILD
  413.  
  414.           Make sure    you have MMS (from Digital) or the freeware
  415.           MMK ( available from MadGoat at  http://www.madgoat.com
  416.           ).  Then type this to create the DESCRIP.MMS for the
  417.           module:
  418.  
  419.           perl Makefile.PL
  420.  
  421.           Now you're ready to build:
  422.  
  423.           mms
  424.           mms test
  425.  
  426.           Substitute mmk for mms above if you're using MMK.
  427.  
  428.           D. INSTALL
  429.  
  430.           Type
  431.  
  432.           mms install
  433.  
  434.           Substitute mmk for mms above if you're using MMK.
  435.  
  436.       +o   IIIIffff yyyyoooouuuu''''rrrreeee    oooonnnn MMMMVVVVSSSS,
  437.  
  438.           Introduce    the .tar.gz file into an HFS as    binary;    don't
  439.           translate    from ASCII to EBCDIC.
  440.  
  441.           A. DECOMPRESS
  442.  
  443.             Decompress the file    with C<gzip -d yourmodule.tar.gz>
  444.  
  445.             You    can get    gzip from
  446.             http://www.s390.ibm.com/products/oe/bpxqp1.html.
  447.  
  448.           B. UNPACK
  449.  
  450.           Unpack the result    with
  451.  
  452.            pax -o to=IBM-1047,from=ISO8859-1 -r    < yourmodule.tar
  453.  
  454.           The BUILD    and INSTALL steps are identical    to those for
  455.           Unix.  Some modules generate Makefiles that work better
  456.  
  457.  
  458.  
  459.      Page 7                        (printed 10/23/98)
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  467.  
  468.  
  469.  
  470.           with GNU make, which is available    from
  471.           http://www.mks.com/s390/gnu/index.htm.
  472.  
  473.      HHHHEEEEYYYY
  474.       If you have any suggested changes for    this page, let me
  475.       know.     Please    don't send me mail asking for help on how to
  476.       install your modules.     There are too many modules, and too
  477.       few Orwants, for me to be able to answer or even acknowledge
  478.       all your questions.  Contact the module author instead, or
  479.       post to comp.lang.perl.modules, or ask someone familiar with
  480.       Perl on your operating system.
  481.  
  482.      AAAAUUUUTTTTHHHHOOOORRRR
  483.       Jon Orwant
  484.  
  485.       orwant@tpj.com
  486.  
  487.       The Perl Journal, http://tpj.com
  488.  
  489.       with invaluable help from Brandon Allbery, Charles Bailey,
  490.       Graham Barr, Dominic Dunlop, Jarkko Hietaniemi, Ben Holzman,
  491.       Tom Horsley, Nick Ing-Simmons, Tuomas    J. Lukka, Laszlo
  492.       Molnar, Chris    Nandor,    Alan Olsen, Peter Prymmer, Gurusamy
  493.       Sarathy, Christoph Spalinger,    Dan Sugalski, Larry Virden,
  494.       and Ilya Zakharevich.
  495.  
  496.       July 22, 1998
  497.  
  498.      CCCCOOOOPPPPYYYYRRRRIIIIGGGGHHHHTTTT
  499.       Copyright (C)    1998 Jon Orwant.  All Rights Reserved.
  500.  
  501.       Permission is    granted    to make    and distribute verbatim    copies
  502.       of this documentation    provided the copyright notice and this
  503.       permission notice are    preserved on all copies.
  504.  
  505.       Permission is    granted    to copy    and distribute modified
  506.       versions of this documentation under the conditions for
  507.       verbatim copying, provided also that they are    marked clearly
  508.       as modified versions,    that the authors' names    and title are
  509.       unchanged (though subtitles and additional authors' names
  510.       may be added), and that the entire resulting derived work is
  511.       distributed under the    terms of a permission notice identical
  512.       to this one.
  513.  
  514.       Permission is    granted    to copy    and distribute translations of
  515.       this documentation into another language, under the above
  516.       conditions for modified versions.
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.      Page 8                        (printed 10/23/98)
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.      PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))22225555////JJJJuuuullll////99998888    ((((ppppeeeerrrrllll 5555....000000005555,,,, ppppaaaattttcccchhhh 00002222))))PPPPEEEERRRRLLLLMMMMOOOODDDDIIIINNNNSSSSTTTTAAAALLLLLLLL((((1111))))
  533.  
  534.  
  535.  
  536.  
  537.  
  538.  
  539.  
  540.  
  541.  
  542.  
  543.  
  544.  
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.  
  587.  
  588.      Page 9                        (printed 10/23/98)
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.